Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scala Soundness scenario 9 to use mend/.within instead of try/catch #561

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

jackgene
Copy link
Collaborator

@jackgene jackgene commented Dec 29, 2024

mend/.within is the idiomatic approach to exception handling in Soundness

Based on feedback from @propensive.

Jon, based on your feedback I was able to simply explicitly annotate the type of req as Text raises HttpError, and that seemed to work. Let me know if you have any concerns with it.

I also considered defining the async block within its own method (in fact I considered doing that for all scenarios earlier on), but decided against it to make the implementation more consistent with all the other implementations.

@jackgene jackgene marked this pull request as draft December 29, 2024 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant